package com.owc.service.admin;

import com.owc.common.enums.StatusEnum;
import com.owc.domain.BaseResult;
import com.owc.domain.dto.admin.WithdrawDetailDTO;
import com.owc.domain.dto.admin.WithdrawListDTO;
import com.owc.domain.entity.TransferRecord;
import com.owc.domain.vo.admin.BatchReviewVo;
import com.owc.domain.vo.admin.CallbackRequest;
import com.owc.domain.vo.admin.ConfirmRequest;
import com.owc.domain.vo.admin.WithdrawVo;
import org.springframework.lang.NonNull;

import java.util.List;

/**
 * @Author xiaom
 * @Date 2019/12/12 17:03
 * @Version 1.0.0
 * @Description <>
 **/
public interface FinanceService {

    /**
     * Get withdraw order list.
     */
    BaseResult<List<WithdrawListDTO>> getWithdrawList(WithdrawVo withdrawVo);

    /**
     * Batch review order.
     */
    Boolean batchReview(BatchReviewVo batchReviewVo) throws Exception;

    BaseResult<Boolean> callbackWallet(CallbackRequest callbackRequest) throws Exception;

    /**
     * Get withdraw detail.
     */
    WithdrawDetailDTO getTransferDetail(@NonNull String transferId);

    /**
     * Retry review withdraw.
     */
    Boolean retryReview(@NonNull String transferId);

    List<WithdrawDetailDTO.DetailBean> getFlowsInfo(String transferId);

    /**
     * Cancel chain order.
     * @param txHash txHash
     */
    BaseResult<Boolean> cancelOrder(@NonNull String txHash) throws Exception;

    /**
     * 更新交易记录的状态
     * @param transferRecord
     */
    void updateOrderStatus(@NonNull TransferRecord transferRecord, StatusEnum statusEnum);
}
